package com.sudo.dao.admin.entity;

import com.sudo.dao.base.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;

@Data
@Table(name = "sys_menu")
@EqualsAndHashCode(callSuper = true)
public class SysMenu extends BaseEntity {
    /**
     * 乐观锁
     */
    @Id
    private Integer id;

    /**
     * 菜单代码
     */
    @Column(name = "menu_code")
    private String menuCode;

    /**
     * 父菜单代码
     */
    @Column(name = "parent_code")
    private String parentCode;

    /**
     * 菜单名称
     */
    @Column(name = "menu_name")
    private String menuName;

    /**
     * 菜单路径
     */
    @Column(name = "menu_url")
    private String menuUrl;

    /**
     * 是否显示 1默认显示
     */
    @Column(name = "status")
    private String status;

    /**
     * 菜单Icon
     */
    @Column(name = "menu_icon")
    private String menuIcon;

    /**
     * 排序
     */
    private Integer sort;

    @Column(name = "note")
    private String note;

    public interface Field{
        String id = "id";
        String menuCode = "menuCode";
        String parentCode = "parentCode";
        String menuName = "menuName";
        String menuUrl = "menuUrl";
        String status = "status";
        String menuIcon = "menuIcon";
        String sort = "sort";
        String note = "note";
    }
}
